home *** CD-ROM | disk | FTP | other *** search
/ HAKERIS 11 / HAKERIS 11.ISO / soft / development / Macromedia RoboHelp X5 / RoboHelpOffice.exe / Data1.cab / _871C067AFBD04457B08C39DAFDCD550F < prev    next >
Encoding:
Text File  |  2003-09-18  |  4.3 KB  |  127 lines

  1. <html>
  2.     <head>
  3.         <title>WF Navpane</title>
  4.         <meta name="GENERATOR" content="Microsoft Visual Studio.NET 7.0">
  5.         <meta name="vs_targetSchema" content="http://schemas.microsoft.com/intellisense/ie5">
  6.         <script language="javascript1.2" src="whver.js"></script>
  7.         <SCRIPT language="javascript">
  8.             function CheckNavRendered()
  9.             {
  10.                 if (gbSafari && !parent.parent.parent.gbNavReloaded)
  11.                 {
  12.                     parent.parent.parent.gbNavReloaded = true;
  13.                     document.location.reload();
  14.                 }
  15.             }
  16.             
  17.         </SCRIPT>
  18.     </head>
  19.     <body onload="CheckNavRendered()" marginwidth="0" marginheight="0">
  20.         <script language="JavaScript">
  21.  
  22.         // Setup for resize in Opera because for some reason Opera doesn't resize the SWF 
  23.         // properly when the browser/frame is resized vertically. In this case, we will
  24.         // reload the navigation pane
  25.         var gstrBsAgent     = navigator.userAgent.toLowerCase();
  26.         var gbGotResize = false;
  27.         var resizeTimerID = -1;
  28.         var gbNavClosed = false;
  29.  
  30.         if (gbOpera || gbKonqueror || (parent.parent.parent.gbVertical && gbIE)) {
  31.             window.onresize = OperaResize;
  32.         }
  33.         function OperaResize() {
  34.             gbGotResize = true;
  35.             if (resizeTimerID == -1) {
  36.                 resizeTimerID = setInterval("CheckMultipleResize()", 100);
  37.             }
  38.         }
  39.         
  40.         // This function is a hack to protect against a series of resize messages coming from the browser.
  41.         // We set a timer, and if we haven't received a resize message since the last timer, we assume
  42.         // the user resize is complete and we proceed with the reload.
  43.         function CheckMultipleResize() {
  44.             if (gbGotResize) {
  45.                 gbGotResize = false;
  46.             } else if (gbNavClosed && gbMac && gbIE) {
  47.                 gbNavClosed = false;
  48.                 clearInterval(resizeTimerID);
  49.                 resizeTimerID = -1;
  50.             } else {
  51.                 clearInterval(resizeTimerID);
  52.                 resizeTimerID = -1;
  53.                 if (gbIE) {
  54.                     var minHeight = 1;
  55.                     if (gbIE6)
  56.                     {
  57.                         minHeight = 0;
  58.                     }
  59.  
  60.                     if (document.body.clientHeight > minHeight) {
  61.                         parent.parent.parent.DoCommand("CmdGetDefaultNav");
  62.                         parent.parent.parent.gsLastFramesetRow = document.body.clientHeight + ", *";
  63.                     }
  64.                 } else {
  65.                     parent.parent.parent.DoCommand("CmdReloadNavigation");
  66.                 }
  67.             }
  68.         }
  69.  
  70.         // This is used to resize the navpane in Safari, because like Opera and Konqueror the SWF is not
  71.         // resized properly when the frame is resize vertically.  To add to this Safari doesn't have an 
  72.         // onresize event so we must check for the size of the frame to determine whether or not the size
  73.         // has changed
  74.  
  75.         var sizeInterval = null;
  76.         var gnPrevHeight = window.innerHeight;
  77.         var gbChanged = false;
  78.  
  79.         function CheckNavSize()
  80.         {
  81.             if (window.innerHeight != gnPrevHeight)
  82.             {
  83.                 gnPrevHeight = window.innerHeight;
  84.                 gbChanged = true;
  85.             }
  86.             else if (gbChanged)
  87.             {
  88.                 gbChanged = false;
  89.                 parent.parent.parent.DoCommand("CmdReloadNavigation");
  90.             }
  91.         }        
  92.     
  93.         if (gbSafari)
  94.         {
  95.             var sizeInterval = setInterval("CheckNavSize()",1000);
  96.         }
  97.         
  98.         ///////////////////////////////
  99.         //
  100.         //  Insert the "Master" SWF
  101.         //
  102.         ///////////////////////////////
  103.         // Build up the variable string we will be sending
  104.         strFlashVars = "uniqueHelpID=" + parent.parent.parent.UniqueID();
  105.         
  106.         // Build tag to document.write
  107.         strObject = "<OBJECT classid='clsid:D27CDB6E-AE6D-11cf-96B8-444553540000' onMouseWheel=\"this.SetVariable('mouseListener.wheelDelta',event.wheelDelta);\" codebase='http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0'";
  108.         strObject += "WIDTH='100%' HEIGHT='100%' id='navpaneSWF' ALIGN='' VIEWASTEXT>";
  109.         strObject += "<PARAM NAME='movie' VALUE='wf_navpane.swf'>";
  110.         strObject += "<PARAM NAME=quality VALUE=high>";
  111.         strObject += "<PARAM NAME='menu' value='false'>";
  112.         
  113.         // FlashVars for Object tag:
  114.         strObject += "<PARAM NAME=FlashVars VALUE='" + strFlashVars + "'>";
  115.         strObject += "<EMBED src='wf_navpane.swf' quality=high menu='false' WIDTH='100%' HEIGHT='100%' NAME='navpaneSWF' swLiveConnect='true' ALIGN='' ";
  116.         
  117.         // FlashVars for Embed tag:
  118.         strObject += "FlashVars='" + strFlashVars + "' ";
  119.         strObject += "TYPE='application/x-shockwave-flash' PLUGINSPAGE='http://www.macromedia.com/go/getflashplayer'>";
  120.         strObject += "</EMBED>";
  121.         strObject += "</OBJECT>";
  122.         
  123.         document.write(strObject);
  124.         </script>
  125.     </body>
  126. </html>
  127.